<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
    <title>学生个人中心</title>
    <link th:href="@{/layui/css/layui.css}" rel="stylesheet"/>
    <style type="text/css">
        table {
            width: 90%;
            font-size: 16px;
            text-align: center;
            margin: 0 auto;
            border-collapse: separate;
            border-spacing: 0;
            border: 2px #e0e0e0;
            margin-top: 20px;
        }

        td {
            border-bottom: 2px solid #eaeaea;
        }

        .tr1 {
            background: #efefef;
            font-size: 14px;
            height: 50px;
        }

        .tr2 {
            height: 60px;
            border-bottom: 2px solid #eaeaea;
            font-size: 13px;
        }


        p {
            text-align: center;
            font-weight: bold;
            font-size: 28px;
        }


        button {
            margin-left: 1190px;
            width: 95px;
            height: 45px;
            border-radius: 5px;
            color: white;
            background-color: #33CCFF;
        }

        li {
            float: left;
            margin-top: 15px;
            margin-left: 10px;
        }

        .p1 {
            margin-left: 15px;
            color: #1e9fff;
        }
        .search{
            width:1300px;
            height:60px;
            margin-top: 30px;
            margin-bottom: 20px;
            margin-left: 55px;
        }
        select{
            width: 15%;
            height: 30px;
            float: left;
            border-radius: 3px;
            border-color: rgb(224, 224, 224);
            border-style: solid;
            border-width: 1px;
            text-indent: 5px;
            margin-left: 10px;
        }
        .selectButton{
            float: left;
            margin-left: 10px;
            height: 30px;
            width: 70px;
            border: none;
            background-color: rgb(22, 155, 213);
            color: white;

        }
        input{
            width:15%;
            height: 30px;
            float: left;
            border-radius: 3px;
            border-color: rgb(224, 224, 224);
            border-style: solid;
            border-width: 1px;
            text-indent: 5px;
            margin-left: 5px;

        }

        /*a:link {*/
        /*    color: #000000;*/
        /*}*/

        /*!* 未访问链接*!*/
        /*a:visited {*/
        /*    color: #001200;*/
        /*}*/

        /*!* 已访问链接 *!*/
        /*a:hover {*/
        /*    color: #72fffd;*/
        /*}*/

        /*!* 鼠标移动到链接上 *!*/


    </style>
</head>

<body class="layui-layout-body">
<div class="layui-layout layui-layout-admin">
    <!-- header -->

    <div th:replace="~{commons/header::header}"></div>
    <!-- left -->
    <div th:replace="~{commons/left::left}"></div>
    <!-- 内容主体区域 -->
    <div class="layui-body">
        <div style="padding:20px 0px 45px 0px;">
            <p>请假申请</p>
            <div class="search">
                <form action="/staffCheckLeave_select" method="get">
                    <select name="leaveApplytime">
                        <option value="0">请选择申请时间</option>
                        <option th:each="getStaffLeaveList:${getStaffLeaveList}"

                                th:text="${getStaffLeaveList.getLeaveApplytime()}"></option>
                        <input type="submit" value="查询" class="selectButton">
                    </select>
                </form>
            </div>
            <table>
                <thead>
                <tr class="tr1">
                    <!--                    <th>序号&lt;!&ndash;staycomeNum&ndash;&gt;</th>-->
                    <th>学号<!--stuId--></th>
                    <th>姓名<!--stuId--></th>
                    <th>年级<!--stuId--></th>
                    <th>申请时间<!--staycomeTime--></th>
                    <th>请假开始时间</th>
                    <th>请假结束时间</th>
                    <th>去向<!--leaveDestination--></th>
                    <th>申请原因<!--  staycomeReason--></th>
                    <th>状态<!--staycomeApplystate--></th>
                    <th>操作</th>
                </tr>
                </thead>

                <tbody>
                <tr class="tr2" th:each="getStaffLeaveList:${getStaffLeaveList}">

                    <td th:text="${getStaffLeaveList.getStuId()}"></td>
                    <td th:text="${getStaffLeaveList.getStuName()}"></td>
                    <td th:text="${getStaffLeaveList.getStuGrade()}"></td>
                    <td>
                        <time th:text="${getStaffLeaveList.getLeaveApplytime()}"></time>
                    </td>
                    <td th:text="${getStaffLeaveList.getLeaveTime()}"></td>
                    <td th:text="${getStaffLeaveList.getLeaveTime2()}"></td>
                    <td th:text="${getStaffLeaveList.getLeaveDestination()}"></td>
                    <td th:text="${getStaffLeaveList.getLeaveReason()}"></td>
                    <td th:if="${getStaffLeaveList.getLeaveApplystate()}==1">审核中</td>
                    <td th:if="${getStaffLeaveList.getLeaveApplystate()}==2">已通过</td>
                    <td th:if="${getStaffLeaveList.getLeaveApplystate()}==3">已撤回</td>
                    <td th:if="${getStaffLeaveList.getLeaveApplystate()}==4">未通过</td>
                    <td>
                        <a class="layui-btn layui-btn-primary layui-btn-xs"
                           th:href="@{'/to_staff_checkLeave/'+${getStaffLeaveList.getLeaveNum()}+'/'+${getStaffLeaveList.getStuId()}}">审批</a>

                    </td>

                </tr>

                </tbody>
            </table>
            <div class="modal-footer no-margin-top" style="font-size: 15px">
                <div class="col-md-6" style="float: left;margin-top: 15px; margin-left: 400px;">
                    当前第 [[${pageInfo.pageNum}]]页,共 [[${pageInfo.pages}]] 页.共 [[${pageInfo.total}]] 条记录
                </div>

                <ul class="pagination pull-right no-margin">
                    <li th:if="${pageInfo.hasPreviousPage}">
                        <a th:href="'/staffCheckLeave?pageNum=1'" class="p1">首页</a>
                    </li>

                    <li class="prev" th:if="${pageInfo.hasPreviousPage}">
                        <a th:href="'/staffCheckLeave?pageNum='+${pageInfo.prePage}" class="p1">
                            <i class="ace-icon fa fa-angle-double-left">上一页</i>
                        </a>
                    </li>
                    <!--遍历条数-->
                    <li th:each="nav:${pageInfo.navigatepageNums}">
                        <a th:href="'/staffCheckLeave?pageNum='+${nav}" th:text="${nav}"
                           th:if="${nav != pageInfo.pageNum}"
                           class="p1"></a>
                        <span style="font-weight: bold;background: #6faed9;" th:if="${nav == pageInfo.pageNum}"
                              th:text="${nav}"></span>
                    </li>

                    <li class="next" th:if="${pageInfo.hasNextPage}">
                        <a th:href="'/staffCheckLeave?pageNum='+${pageInfo.nextPage}" class="p1">
                            <i class="ace-icon fa fa-angle-double-right">下一页</i>
                        </a>
                    </li>

                    <li>
                        <a th:href="'/staffCheckLeave?pageNum='+${pageInfo.pages}" class="p1">尾页</a>
                    </li>
                </ul>
            </div>
        </div>
    </div>
</div>
<script th:src="@{/layui/layui.js}"></script>
<script>
    //JavaScript代码区域
    layui.use('element', function () {
        var element = layui.element;
    });
</script>

</body>
</html>